<template>
  <div class="background el-button el-button--default el-button--mini">
    <span class="desc">背景色</span>
    <el-color-picker v-model="color" @change="onColorChange" />
  </div>
</template>
<script>
export default {
  name: 'Background',
  data() {
    return {
      color: '#FFFFFF'
    }
  },
  methods: {
    onColorChange(color) {
      this.$emit('color', color)
    }
  }
}
</script>
<style lang="scss" scoped>
.background {
  display: flex;
  align-items: center;
  justify-content: center;
  .desc {
    margin-right: 5px;
  }
}
</style>
